<?php
$connection = new MongoClient();
$db = $connection->selectDB('test');
$collection = $db->selectCollection('users');
$collection->createIndex(['i' => 1]);   //升序建立索引
